package com.example.qrcode.mapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Param;
import com.example.qrcode.entity.SceneBindingDi;
import java.util.List;

@Mapper
public interface SceneBindingDiMapper extends BaseMapper<SceneBindingDi> {

    @Select("SELECT * FROM t_scene_binding_di WHERE device_code = #{deviceCode}")
    List<SceneBindingDi> getSceneBindingDiByDeviceCode(String deviceCode);

    @Select("SELECT * FROM t_scene_binding_di WHERE graphic_name = #{graphicName}")
    List<SceneBindingDi> getSceneBindingDiByGraphicName(@Param("graphicName") String graphicName);
    
    @Select("SELECT * FROM t_scene_binding_di WHERE scene_id = #{sceneId}")
    List<SceneBindingDi> getSceneBindingDiBySceneId(@Param("sceneId") Integer sceneId);
}

